From 81d1ab240339d5b3b2bc1b8dc41ef45e63bdea0f Mon Sep 17 00:00:00 2001 From: Ramakrishnan Muthukrishnan Date: Wed, 17 Feb 2016 13:41:00 +0530 Subject: [PATCH] document "cargo init" --- src/bin/cargo.rs | 1 + src/etc/cargo.1 | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/src/bin/cargo.rs b/src/bin/cargo.rs index 1ad07cf37..350448df0 100644 --- a/src/bin/cargo.rs +++ b/src/bin/cargo.rs @@ -44,6 +44,7 @@ Some common cargo commands are: clean Remove the target directory doc Build this project's and its dependencies' documentation new Create a new cargo project + init Create a new cargo project in an existing directory run Build and execute src/main.rs test Run the tests bench Run the benchmarks diff --git a/src/etc/cargo.1 b/src/etc/cargo.1 index ea053d83b..db4971d23 100644 --- a/src/etc/cargo.1 +++ b/src/etc/cargo.1 @@ -44,6 +44,9 @@ Remove the target directory with build output \fBcargo doc\fR Build this project's and its dependencies' documentation .TP +\fBcargo init\fR +Create a new cargo project in the current directory +.TP \fBcargo install\fR Install a Rust binary .TP @@ -90,6 +93,13 @@ Build a package with optimizations Run tests for a cross-compiled target $ cargo test --target i686-unknown-linux-gnu +Create a new project that builds an executable + $ cargo new --init foobar + +Create a project in the current directory + $ mkdir foo && cd foo + $ cargo init . + Learn about a command's options and usage $ cargo help clean -- 2.30.2